<template>
  <div>
    <h3 @click="hClick">这个son组件---navite</h3>
    <button @click="hUpdate" />
  </div>
</template>

<script>
export default {
  methods: {
    hClick() {
      this.$emit('hClick')
    },
    hUpdate() {
      // this.num++ 不能直接修改父组件的值 this.num = this.num ++
      this.$emit('update:a', this.a + 1)
      this.$emit('update:b', this.b - 1)
    }
  }
}
</script>

